using System;
using System.Collections.Generic;
using UnityEngine;

public class DailyPrizesConfig : ScriptableObject
{
	[Serializable]
	public class Prize
	{
		public string spriteName;

		public int prize;
	}

	public int minTimeHours;

	protected static DailyPrizesConfig instance_;

	public List<Prize> prizes = new List<Prize>();

	public static DailyPrizesConfig instance
	{
		get
		{
			if (instance_ == null)
			{
				instance_ = Resources.Load("DailyPrizesConfig", typeof(DailyPrizesConfig)) as DailyPrizesConfig;
			}
			return instance_;
		}
	}

	public Prize PrizeForConsecutiveDays(int consecutiveDays)
	{
		consecutiveDays = Mathf.Clamp(consecutiveDays, 0, instance.prizes.Count - 1);
		return prizes[consecutiveDays];
	}
}
